< previous page page_701 next page >

Page 701
0701-01.jpg
Figure 18.7.
Displaying the RDO Engine properties.
The rdoEnvironment Object
The rdoEnvironment object contains information about the current environment for data connections. The rdoEnvironment object is the RDO equivalent of the Microsoft Jet Workspaces object. rdoEnvironment objects can be used to group rdoConnection objects together for transaction-management purposes as well.
You can create multiple rdoEnvironment objects under the rdoEngine object. All rdoEnvironment objects are contained in the rdoEnvironments collection object.
Add a new button to the form. Set its Name property to cmdRDOEnvironment and its Caption to Environment. Now enter the code from Listing 18.8 to the cmdRDOEnvironment_Click event.
Type.gifListing 18.8. Coding the cmdRDOEnvironment_Click event.
Private Sub cmdRDOEnvironment_Click()
    '
    ' show environment collection as properties
    '
    Dim strMsg As String
    Dim rdoEnv As rdoEnvironment
    Dim rdoNewEnv As rdoEnvironment
    Dim aryCursorDriver As Variant
    '
    aryCursorDriver = Array("rdUseIfNeeded", "rdUseOdbc", "rdUseServer",
arrow.gif"rdUseClientBatch", "rduseNone")
    '
    Set rdoNewEnv = rdoEngine.rdoCreateEnvironment("rdoTEMP", "admin", "")
    '
    For Each rdoEnv In rdoEngine.rdoEnvironments
        strMsg = strMsg & "rdoCursorDriver=" &
arrow.gifaryCursorDriver(rdoEnv.CursorDriver) & vbCrLf
        strMsg = strMsg & "hEnv=" & CStr(rdoEnv.hEnv) & vbCrLf
        strMsg = strMsg & "LoginTimeOut=" & CStr(rdoEnv.LoginTimeout) & vbCrLf
        strMsg = strMsg & "Name=" & rdoEnv.Name & vbCrLf
continues

 
< previous page page_701 next page >

If you like this book, buy it!